Optimal. Leaf size=172 \[ -\frac {e f^2 p}{4 d x^2}-\frac {e^2 f^2 p \log (x)}{2 d^2}+\frac {2 e f g p \log (x)}{d}+\frac {e^2 f^2 p \log \left (d+e x^2\right )}{4 d^2}-\frac {e f g p \log \left (d+e x^2\right )}{d}-\frac {f^2 \log \left (c \left (d+e x^2\right )^p\right )}{4 x^4}-\frac {f g \log \left (c \left (d+e x^2\right )^p\right )}{x^2}+\frac {1}{2} g^2 \log \left (-\frac {e x^2}{d}\right ) \log \left (c \left (d+e x^2\right )^p\right )+\frac {1}{2} g^2 p \text {Li}_2\left (1+\frac {e x^2}{d}\right ) \]
[Out]
________________________________________________________________________________________
Rubi [A]
time = 0.15, antiderivative size = 172, normalized size of antiderivative = 1.00, number of steps
used = 12, number of rules used = 10, integrand size = 25, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.400, Rules used = {2525, 45,
2463, 2442, 46, 36, 29, 31, 2441, 2352} \begin {gather*} \frac {1}{2} g^2 p \text {PolyLog}\left (2,\frac {e x^2}{d}+1\right )-\frac {f^2 \log \left (c \left (d+e x^2\right )^p\right )}{4 x^4}-\frac {f g \log \left (c \left (d+e x^2\right )^p\right )}{x^2}+\frac {1}{2} g^2 \log \left (-\frac {e x^2}{d}\right ) \log \left (c \left (d+e x^2\right )^p\right )+\frac {e^2 f^2 p \log \left (d+e x^2\right )}{4 d^2}-\frac {e^2 f^2 p \log (x)}{2 d^2}-\frac {e f^2 p}{4 d x^2}-\frac {e f g p \log \left (d+e x^2\right )}{d}+\frac {2 e f g p \log (x)}{d} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
Rule 29
Rule 31
Rule 36
Rule 45
Rule 46
Rule 2352
Rule 2441
Rule 2442
Rule 2463
Rule 2525
Rubi steps
\begin {align*} \int \frac {\left (f+g x^2\right )^2 \log \left (c \left (d+e x^2\right )^p\right )}{x^5} \, dx &=\frac {1}{2} \text {Subst}\left (\int \frac {(f+g x)^2 \log \left (c (d+e x)^p\right )}{x^3} \, dx,x,x^2\right )\\ &=\frac {1}{2} \text {Subst}\left (\int \left (\frac {f^2 \log \left (c (d+e x)^p\right )}{x^3}+\frac {2 f g \log \left (c (d+e x)^p\right )}{x^2}+\frac {g^2 \log \left (c (d+e x)^p\right )}{x}\right ) \, dx,x,x^2\right )\\ &=\frac {1}{2} f^2 \text {Subst}\left (\int \frac {\log \left (c (d+e x)^p\right )}{x^3} \, dx,x,x^2\right )+(f g) \text {Subst}\left (\int \frac {\log \left (c (d+e x)^p\right )}{x^2} \, dx,x,x^2\right )+\frac {1}{2} g^2 \text {Subst}\left (\int \frac {\log \left (c (d+e x)^p\right )}{x} \, dx,x,x^2\right )\\ &=-\frac {f^2 \log \left (c \left (d+e x^2\right )^p\right )}{4 x^4}-\frac {f g \log \left (c \left (d+e x^2\right )^p\right )}{x^2}+\frac {1}{2} g^2 \log \left (-\frac {e x^2}{d}\right ) \log \left (c \left (d+e x^2\right )^p\right )+\frac {1}{4} \left (e f^2 p\right ) \text {Subst}\left (\int \frac {1}{x^2 (d+e x)} \, dx,x,x^2\right )+(e f g p) \text {Subst}\left (\int \frac {1}{x (d+e x)} \, dx,x,x^2\right )-\frac {1}{2} \left (e g^2 p\right ) \text {Subst}\left (\int \frac {\log \left (-\frac {e x}{d}\right )}{d+e x} \, dx,x,x^2\right )\\ &=-\frac {f^2 \log \left (c \left (d+e x^2\right )^p\right )}{4 x^4}-\frac {f g \log \left (c \left (d+e x^2\right )^p\right )}{x^2}+\frac {1}{2} g^2 \log \left (-\frac {e x^2}{d}\right ) \log \left (c \left (d+e x^2\right )^p\right )+\frac {1}{2} g^2 p \text {Li}_2\left (1+\frac {e x^2}{d}\right )+\frac {1}{4} \left (e f^2 p\right ) \text {Subst}\left (\int \left (\frac {1}{d x^2}-\frac {e}{d^2 x}+\frac {e^2}{d^2 (d+e x)}\right ) \, dx,x,x^2\right )+\frac {(e f g p) \text {Subst}\left (\int \frac {1}{x} \, dx,x,x^2\right )}{d}-\frac {\left (e^2 f g p\right ) \text {Subst}\left (\int \frac {1}{d+e x} \, dx,x,x^2\right )}{d}\\ &=-\frac {e f^2 p}{4 d x^2}-\frac {e^2 f^2 p \log (x)}{2 d^2}+\frac {2 e f g p \log (x)}{d}+\frac {e^2 f^2 p \log \left (d+e x^2\right )}{4 d^2}-\frac {e f g p \log \left (d+e x^2\right )}{d}-\frac {f^2 \log \left (c \left (d+e x^2\right )^p\right )}{4 x^4}-\frac {f g \log \left (c \left (d+e x^2\right )^p\right )}{x^2}+\frac {1}{2} g^2 \log \left (-\frac {e x^2}{d}\right ) \log \left (c \left (d+e x^2\right )^p\right )+\frac {1}{2} g^2 p \text {Li}_2\left (1+\frac {e x^2}{d}\right )\\ \end {align*}
________________________________________________________________________________________
Mathematica [A]
time = 0.09, size = 148, normalized size = 0.86 \begin {gather*} \frac {1}{4} \left (\frac {4 e f g p \left (2 \log (x)-\log \left (d+e x^2\right )\right )}{d}-\frac {e f^2 p \left (d+2 e x^2 \log (x)-e x^2 \log \left (d+e x^2\right )\right )}{d^2 x^2}-\frac {f^2 \log \left (c \left (d+e x^2\right )^p\right )}{x^4}-\frac {4 f g \log \left (c \left (d+e x^2\right )^p\right )}{x^2}+2 g^2 \left (\log \left (-\frac {e x^2}{d}\right ) \log \left (c \left (d+e x^2\right )^p\right )+p \text {Li}_2\left (1+\frac {e x^2}{d}\right )\right )\right ) \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
Maple [C] Result contains higher order function than in optimal. Order 9 vs. order
4.
time = 0.45, size = 663, normalized size = 3.85
method | result | size |
risch | \(\frac {2 e f g p \ln \left (x \right )}{d}-\frac {e f g p \ln \left (e \,x^{2}+d \right )}{d}+\frac {e^{2} f^{2} p \ln \left (e \,x^{2}+d \right )}{4 d^{2}}-\frac {e^{2} f^{2} p \ln \left (x \right )}{2 d^{2}}-\frac {e \,f^{2} p}{4 d \,x^{2}}+\frac {i \pi \,\mathrm {csgn}\left (i \left (e \,x^{2}+d \right )^{p}\right ) \mathrm {csgn}\left (i c \left (e \,x^{2}+d \right )^{p}\right ) \mathrm {csgn}\left (i c \right ) f g}{2 x^{2}}-p \,g^{2} \dilog \left (\frac {-e x +\sqrt {-e d}}{\sqrt {-e d}}\right )-p \,g^{2} \dilog \left (\frac {e x +\sqrt {-e d}}{\sqrt {-e d}}\right )+\frac {i \pi \mathrm {csgn}\left (i c \left (e \,x^{2}+d \right )^{p}\right )^{3} f^{2}}{8 x^{4}}-\frac {i \pi \mathrm {csgn}\left (i c \left (e \,x^{2}+d \right )^{p}\right )^{3} g^{2} \ln \left (x \right )}{2}-\frac {\ln \left (\left (e \,x^{2}+d \right )^{p}\right ) f g}{x^{2}}-p \,g^{2} \ln \left (x \right ) \ln \left (\frac {-e x +\sqrt {-e d}}{\sqrt {-e d}}\right )-p \,g^{2} \ln \left (x \right ) \ln \left (\frac {e x +\sqrt {-e d}}{\sqrt {-e d}}\right )-\frac {\ln \left (c \right ) f g}{x^{2}}+\frac {i \pi \mathrm {csgn}\left (i c \left (e \,x^{2}+d \right )^{p}\right )^{3} f g}{2 x^{2}}-\frac {i \pi \mathrm {csgn}\left (i c \left (e \,x^{2}+d \right )^{p}\right )^{2} \mathrm {csgn}\left (i c \right ) f^{2}}{8 x^{4}}+\frac {i \pi \mathrm {csgn}\left (i c \left (e \,x^{2}+d \right )^{p}\right )^{2} \mathrm {csgn}\left (i c \right ) g^{2} \ln \left (x \right )}{2}-\frac {i \pi \,\mathrm {csgn}\left (i \left (e \,x^{2}+d \right )^{p}\right ) \mathrm {csgn}\left (i c \left (e \,x^{2}+d \right )^{p}\right )^{2} f^{2}}{8 x^{4}}+\frac {i \pi \,\mathrm {csgn}\left (i \left (e \,x^{2}+d \right )^{p}\right ) \mathrm {csgn}\left (i c \left (e \,x^{2}+d \right )^{p}\right )^{2} g^{2} \ln \left (x \right )}{2}-\frac {\ln \left (\left (e \,x^{2}+d \right )^{p}\right ) f^{2}}{4 x^{4}}+\ln \left (\left (e \,x^{2}+d \right )^{p}\right ) g^{2} \ln \left (x \right )+\ln \left (c \right ) g^{2} \ln \left (x \right )-\frac {\ln \left (c \right ) f^{2}}{4 x^{4}}-\frac {i \pi \,\mathrm {csgn}\left (i \left (e \,x^{2}+d \right )^{p}\right ) \mathrm {csgn}\left (i c \left (e \,x^{2}+d \right )^{p}\right )^{2} f g}{2 x^{2}}+\frac {i \pi \,\mathrm {csgn}\left (i \left (e \,x^{2}+d \right )^{p}\right ) \mathrm {csgn}\left (i c \left (e \,x^{2}+d \right )^{p}\right ) \mathrm {csgn}\left (i c \right ) f^{2}}{8 x^{4}}-\frac {i \pi \,\mathrm {csgn}\left (i \left (e \,x^{2}+d \right )^{p}\right ) \mathrm {csgn}\left (i c \left (e \,x^{2}+d \right )^{p}\right ) \mathrm {csgn}\left (i c \right ) g^{2} \ln \left (x \right )}{2}-\frac {i \pi \mathrm {csgn}\left (i c \left (e \,x^{2}+d \right )^{p}\right )^{2} \mathrm {csgn}\left (i c \right ) f g}{2 x^{2}}\) | \(663\) |
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Maxima [A]
time = 1.24, size = 172, normalized size = 1.00 \begin {gather*} \frac {1}{2} \, {\left (\log \left (x^{2} e + d\right ) \log \left (-\frac {x^{2} e + d}{d} + 1\right ) + {\rm Li}_2\left (\frac {x^{2} e + d}{d}\right )\right )} g^{2} p + \frac {{\left (4 \, d f g p e + 2 \, d^{2} g^{2} \log \left (c\right ) - f^{2} p e^{2}\right )} \log \left (x\right )}{2 \, d^{2}} - \frac {d^{2} f^{2} \log \left (c\right ) + {\left (d f^{2} p e + 4 \, d^{2} f g \log \left (c\right )\right )} x^{2} + {\left (4 \, d^{2} f g p x^{2} + d^{2} f^{2} p + {\left (4 \, d f g p e - f^{2} p e^{2}\right )} x^{4}\right )} \log \left (x^{2} e + d\right )}{4 \, d^{2} x^{4}} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Fricas [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {could not integrate} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Sympy [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \int \frac {\left (f + g x^{2}\right )^{2} \log {\left (c \left (d + e x^{2}\right )^{p} \right )}}{x^{5}}\, dx \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Giac [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {could not integrate} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Mupad [F]
time = 0.00, size = -1, normalized size = -0.01 \begin {gather*} \int \frac {\ln \left (c\,{\left (e\,x^2+d\right )}^p\right )\,{\left (g\,x^2+f\right )}^2}{x^5} \,d x \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________